package fnord.jovian.tango;

import fnord.jovian.TheBoard;
import fnord.jovian.tango.TheAssemblyLayout.TheAssemblyOrientation;

public class TheTransferableMenu extends TheMenu {

	public TheTransferableMenu(TheBoard board) {
		super(300, 200, board);
		_mask = null;
		TheAssemblyLayout layout = new TheAssemblyLayout(TheAssemblyOrientation.VERTICAL);
		setTheLayout(layout);
		this.addComponent(new TheButton("Add Transferable Power", 200, 30, new TheTransferableListener()));
		this.addComponent(new TheButton("Continue Attack", 200, 30, new TheContinueListener()));
		this.addComponent(new TheButton("Cancel Attack", 200, 30, new TheCancelListener()));
	}
	private class TheTransferableListener implements TheListener {
        public void doAction() {
			_board.addTransferable();
        }
	}
	private class TheContinueListener implements TheListener {
        public void doAction() {
			_board.continueAttack();
        }
	}
	
	private class TheCancelListener implements TheListener {
		public void doAction() {
			_board.cancelAction();
		}
	}
	
}
